package com.longshihan.module_sample.huazhu.mvp.model.impl

import com.longshihan.module_base.utils.AppService
import com.longshihan.module_sample.huazhu.http.ApiService
import com.longshihan.module_sample.huazhu.http.*
import com.longshihan.module_sample.huazhu.mvp.model.entity.AppEntity
import com.longshihan.module_sample.huazhu.mvp.model.entity.HuaZhuJsonObject
import com.longshihan.mvplh.mvp.BaseModel
import com.longshihan.mvplh.mvp.IRepositoryManager

import io.reactivex.Observable

/**
 * Created by LONGHE001.
 *
 * @time 2017/11/21 0021
 * @des
 * @function
 */

class LoadingImpl(repositoryManager: IRepositoryManager) : BaseModel(repositoryManager), ILoading {

    override fun loadData(map: String): Observable<HuaZhuJsonObject<AppEntity>> {
        return mRepositoryManager
                .obtainRetrofitService(ApiService::class.java).getStart(map)
    }
}
